Component({
  properties: {
    showScreens: {
      type: Boolean,
      value: true
    },
    showPromotion: {
      type: Boolean,
      value: true
    },
    showTabBaer: {
      type: Boolean,
      value: true
    },
    showMore: {
      type: Boolean,
      value: true
    },
  },
	data: {
		selected: "",
		color: "#636363",
		selectedColor: "#2b8ce6",
		// showScreens: true,
		// showPromotion: true,
		// showTabBaer:true,
    // showMore:true,
		list: [{
				"text": "首页",
				"name": "index",
				"pagePath": "/pages/tasks/list/list",
				"iconPath": "/images/tabbar/home.png",
				"selectedIconPath": "/images/tabbar/home-selected.png"
			},
			{
				"text": "筛查",
				"name": "screen",
				"pagePath": "/pages/screens/list/list",
				"iconPath": "/images/tabbar/filter.png",
				"selectedIconPath": "/images/tabbar/filter-selected.png"
			},
			{
				"text": "学术推广",
				"name": "promotion",
				"iconPath": "/images/tabbar/phone.png",
				"selectedIconPath": "/images/tabbar/phone-selected.png",
				"pagePath": "/pages/promotion/index/index"
			},
			{
				"text": "设置",
				"name": "setting",
				"iconPath": "/images/tabbar/me.png",
				"selectedIconPath": "/images/tabbar/me-selected.png",
				"pagePath": "/pages/settings/myinfo/myinfo"
			}
		]
	},
	created() {


	},
	methods: {
		switchTab(e) {
			const data = e.currentTarget.dataset
			const url = data.path
			wx.switchTab({
				url
			})
			this.setData({
				selected: data.name
			})
		}
	}
})
